﻿@using king.models;
@model IEnumerable<Product>;
@{Layout=null;}
<style>
    table,td
    {
        border: 2px solid;
    }
</style>

<table>
             
    <input type="button" id="jia" value="增加" ">
    <input type="text" name="key"placeholder="输入关键"><input type="button" id="cha"" value="查找" ">
    <tr>
        <td>ID</td>
        <td>商品名称</td>
        <td>供应商名称</td>
        <td>价格</td>
        <td>库存数量</td>
        <td>备注</td>
        <td>操作</td>
    </tr>
    @foreach (var item in Model)
    {
    <tr>
        <td>@item.Id</td>
        <td>@item.ProductName</td>
        <td>@item.Supplier</td>
        <td>@item.Price</td>
        <td>@item.Stock</td>
        <td>@item.Remarks</td>
        <td>
            <input type="button" class="sha" value="删除" onclick="sha(@item.Id)">
            <input type="button" class="bian" value="编辑" onclick="bian(@item.Id)">
        </td>
    </tr>
    }



</table>


<script src="~/root/lib/jquery/dist/jquery.min.js"></script>
<script src="~/js/base.js"></script>



